import { createStore } from "vuex";

export default createStore({
  state: {
    isCollapse: false,
    userInfo: {},
  },
  mutations: {
    // 控制 aside 是否显示完全
    showAside(state) {
      state.isCollapse = !state.isCollapse;
    },
    saveUserInfo(state, info) {
      state.userInfo = { ...info };
    },
  },
  actions: {},
  modules: {},
});
